<style type="text/css">
    #phantrang{
        padding: 5px;
    }
    #phantrang a{
     padding: 3px 7px 3px 7px; 
     color: #000;
     text-decoration: none;
     margin: 0px 5px;
     background: #ccc;
    }
    #phantrang .current{
         padding: 3px 7px 3px 7px; 
        border: 1px solid #ccc;
        color: darkcyan;
        font-weight: bold;
    }
    #phantrang .disabled{
         padding: 3px 7px 3px 7px; 
        color: #ccc;
        border: 1px solid #ccc;
        margin: 0px 5px;
    }
</style>
<?php
require_once 'model/keywords.php';
require_once 'model/pagination.php';
$paginations=new pagination();
$keyword = new keywords();
$keyword->table_name = "works";
?>
<?php
if (!isset($_GET["page"]))
    $page = 1;
else
    $page = $_GET["page"];
$keywords = $keyword->select($page);
$total = $keyword->countWords();
var_dump($total);
echo $paginations->showPagination($page, $total,null,"index.php");
?>
<?php
foreach ($keywords as $item):
    echo $item["id"] . ": ";
    echo $item["name"] . "<br>";
endforeach;
?>


